#define  _CRT_SECURE_NO_WARNINGS 1
#include<iostream>
using namespace std;
int main()
{
	long long int a, b,n;
	//long long int ret1 = 0;
	scanf("%lld %lld %lld", &a, &b,&n);
	long long int ret2 = n / (5 * a + 2 * b);
	long long int ret1 = n % (5 * a + 2 * b);
	long long int ret = 0;
	while (ret1 > 0)
	{
		ret++;
		if (ret % 7 <= 5 && ret % 7 > 0)
			ret1 -= a;
		else
			ret1 -= b;
	}
	ret += ret2 * 7;
	cout << ret << endl;
	
}